
goog.provide('esn.model.QuestionModel');


/**
 * @constructor
 */
esn.model.QuestionModel = function(model, sectionId) {
  this.model_ = model;
  this.sectionId_ = sectionId;
};

esn.model.QuestionModel.prototype.getId = function() {
  return this.model_.ID;
};

esn.model.QuestionModel.prototype.getSectionId = function() {
  return this.sectionId_;
};

esn.model.QuestionModel.prototype.getQuestion = function() {
  return this.model_.QUESTION;
};

esn.model.QuestionModel.prototype.getDescription = function() {
  return this.model_.DESCRIPTION;
};

esn.model.QuestionModel.prototype.getPossibleAnswers = function() {
  return this.model_.POSSIBLE_ANSWERS;
};

esn.model.QuestionModel.prototype.getType = function() {
  return this.model_.TYPE;
};

esn.model.QuestionModel.prototype.getInputSize = function() {
  return this.model_.INPUT_SIZE || esn.constants.DEFAULT_INPUT_SIZE;
};

esn.model.QuestionModel.prototype.isMultiInput = function() {
  return this.getType() == esn.constants.QuestionType.INPUT &&
      this.model_.POSSIBLE_ANSWERS.length > 1;
};

esn.model.QuestionModel.prototype.toObject = function() {
  return this.model_;
};
